import java.util.Iterator;

import utils.Filter;

/**
 * A kind of Filter that lets all the VALUE elements of its input sequence
 * through.
 *
 * @author Mingjie Chen
 */
class TrivialFilter<Value> extends Filter<Value> {

    /**
     * A filter of values from INPUT that simply delivers all of them.
     */
    TrivialFilter(Iterator<Value> input) {
        super(input);
        this._input = input;
        this._valid = false;
    }

    @Override
    protected boolean keep() {
        return _next!=null;
    }

    private Iterator<Value> _input;
    private boolean _valid;
}
